const mongoose=require('mongoose')
mongoose.connect('mongodb://localhost/1208')
mongoose.connection.on('open',(req,res)=>{
    console.log('连接成功');
})
mongoose.connection.on('error',(req,res)=>{
    console.log('连接失败');
})
module.exports = mongoose;